package com.language.tureng_wg;

import android.os.Bundle;
import android.app.Activity;
import android.content.Intent;
import android.view.Menu;
import android.widget.Toast;

public class SplashActivity extends Activity {

	Intent intent;

	@Override
	public void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_splash);

		intent = new Intent("com.language.tureng_wg.MENU");
		Thread th = new Thread() {

			@Override
			public void run() {
				try {
					super.run();
					sleep(5000);
				} catch (Exception e) {
					Toast.makeText(SplashActivity.this,
							"Hata:" + e.getMessage(), RESULT_OK);
				} finally {
					startActivity(intent);
				}
			}
		};
		th.start();

	}

	@Override
	public boolean onCreateOptionsMenu(Menu menu) {
		getMenuInflater().inflate(R.menu.activity_splash, menu);
		return true;
	}
}
